import 'package:flutter/material.dart';
import 'package:untitled/root_page.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: myHome(),
    );
  }

}

class MyHomePage extends StatelessWidget {
 // int _currentIndex = 0;
  @override
   Widget build(BuildContext context){
     return  Container(
       color: Colors.green,
       child: Scaffold(
         bottomNavigationBar: BottomNavigationBar(
           type: BottomNavigationBarType.fixed,
           fixedColor: Colors.green,
           currentIndex: 1,
           items:const [
            BottomNavigationBarItem(icon: Icon(Icons.chat),label: '聊天'),
            BottomNavigationBarItem(icon: Icon(Icons.bookmark),label: '列表'),
             BottomNavigationBarItem(icon: Icon(Icons.history),label: '列表'),
             BottomNavigationBarItem(icon:Icon(Icons.ice_skating), label: '列表')
           ],
         ),
       ),
     );
   }

}

